package com.xcity.pomelo.push.msg;

import naga.x.net.impl.pomelo.PomeloMessage;
import naga.x.net.impl.pomelo.protocol.Message;

import com.xcity.db.entity.Player;
import com.xcity.pomelo.PomeloRoute;
import com.xcity.pomelo.push.AbstractMessagePush;

@PomeloMessage(type = Message.Type.PUSH, route = PomeloRoute.PUSH_MESSAGE)
public class LandBeAcquiredPush extends AbstractMessagePush {
//	msgId: 'onInCome',
//    content: {
//        landName: land.name,
//        roleName: roler.roleName,
//        gold: oRoler.gold,
//        totalGold: oRoler.totalGold,
//        stone: oRoler.stone,
//        curLands: tools.conversionRolerCurLandsdData(oRoler)
//    }
	
	private LandInfo content;
	
	public static class LandInfo {
		private String landName;
		private String roleName;
		private long gold;
		private long totalGold;
		private int stone;
		public String getLandName() {
			return landName;
		}
		public void setLandName(String landName) {
			this.landName = landName;
		}
		public String getRoleName() {
			return roleName;
		}
		public void setRoleName(String roleName) {
			this.roleName = roleName;
		}
		public long getGold() {
			return gold;
		}
		public void setGold(long gold) {
			this.gold = gold;
		}
		public long getTotalGold() {
			return totalGold;
		}
		public void setTotalGold(long totalGold) {
			this.totalGold = totalGold;
		}
		public int getStone() {
			return stone;
		}
		public void setStone(int stone) {
			this.stone = stone;
		}
	}
	
	public LandBeAcquiredPush(String land, String targetPlayer, Player player) {
		super(MSG_LAND_BE_ACQUIRED);
		content = new LandInfo();
		content.landName = land;
		content.roleName = targetPlayer;
		content.gold = player.getGold();
		content.totalGold = player.getFixedAssets();
		content.stone = player.getStone();
	}

	public LandInfo getContent() {
		return content;
	}

	public void setContent(LandInfo content) {
		this.content = content;
	}
	
}
